﻿@model mvcForum.Web.ViewModels.RegisterModel
@using mvcForum.Web.Helpers;
@{
	ViewBag.Title = ForumHelper.GetString("Register.Title");

	Layout = Url.GetThemeBaseUrl() + "areas/forum/views/shared/forumlayout.cshtml";
}
	<div class="row">
		<div class="col-md-12">
			<h3>@ForumHelper.GetString("Register.Headline")</h3>
			@using (Html.BeginForm("register", "account", FormMethod.Post, new { @class = "form-horizontal" })) {
@Html.Partial("ModelStateErrors", ViewData.ModelState)
if (Model.RequireRulesAccept) {
				<p>
					@Html.Raw(Model.SignUpRules)
				</p>
				<div class="form-group">
					<div class="col-lg-10">
						<label class="col-lg-2 control-label" for="RememberMe">
							@Html.CheckBoxFor(x => x.RulesAccepted)
							@ForumHelper.GetString("Register.Accept", null, "mvcForum.Web")
						</label>
					</div>
				</div>
}
				<div class="form-group">
					@Html.LabelFor(t => t.Username, new { @class = "col-lg-2 control-label" })
					<div class="col-lg-10">
						@Html.TextBoxFor(x => x.Username, new { @class = "form-control" })
					</div>
				</div>
				<div class="form-group">
					@Html.LabelFor(t => t.EmailAddress, new { @class = "col-lg-2 control-label" })
					<div class="col-lg-10">
						@Html.TextBoxFor(x => x.EmailAddress, new { @class = "form-control" })
					</div>
				</div>
				<div class="form-group">
					@Html.LabelFor(t => t.Password, new { @class = "col-lg-2 control-label" })
					<div class="col-lg-10">
						@Html.PasswordFor(x => x.Password, new { @class = "form-control" })
					</div>
				</div>
				<div class="form-group">
					@Html.LabelFor(t => t.ConfirmPassword, new { @class = "col-lg-2 control-label" })
					<div class="col-lg-10">
						@Html.PasswordFor(x => x.ConfirmPassword, new { @class = "form-control" })
					</div>
				</div>
				<div class="form-group">
					<div class="col-lg-offset-2 col-lg-10">
						<button type="submit" class="btn btn-primary">@ForumHelper.GetString("Register.Submit")</button>
					</div>
				</div>
			}
		</div>
	</div>
